Skip to content

Pricing page more transparent#5531

Merged
colegottdank merged 1 commit intomainfrom
pricing-page-storage
Jan 20, 2026
Merged

Pricing page more transparent#5531
colegottdank merged 1 commit intomainfrom
pricing-page-storage

Conversation

@colegottdank
Copy link
Collaborator

No description provided.

@vercel
Copy link

vercel bot commented Jan 19, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Review Updated (UTC)
helicone-bifrost Ready Ready Preview, Comment Jan 19, 2026 8:57pm
2 Skipped Deployments
Project Deployment Review Updated (UTC)
helicone Skipped Skipped Jan 19, 2026 8:57pm
helicone-eu Skipped Skipped Jan 19, 2026 8:57pm

Request Review

Copy link
Contributor

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Your free trial has ended. If you'd like to continue receiving code reviews, you can add a payment method here.

@supabase
Copy link

supabase bot commented Jan 19, 2026

This pull request has been ignored for the connected project bolqqmqbrciybnypvklh because there are no changes detected in supbase/supabase directory. You can change this behaviour in Project Integrations Settings ↗︎.


Preview Branches by Supabase.
Learn more about Supabase Branching ↗︎.

@supabase
Copy link

supabase bot commented Jan 19, 2026

This pull request has been ignored for the connected project lmahfbbnchpworytrrqk because there are no changes detected in .supabase/supabase directory. You can change this behaviour in Project Integrations Settings ↗︎.


Preview Branches by Supabase.
Learn more about Supabase Branching ↗︎.

@claude
Copy link
Contributor

claude bot commented Jan 19, 2026

Claude finished @colegottdank's task —— View job


Code Review Complete

I've conducted a comprehensive review of this pricing page transparency PR. Here's my detailed analysis:

Review Checklist:

  • Analyze new UsageEstimator component
  • Review refactored PricingComparisonTable
  • Check other modified components
  • Assess code quality and best practices
  • Verify design system compliance
  • Check for performance and security issues
  • Provide final score and recommendations

Score: 7/10 - Good implementation with minor improvements needed

Strengths:

1. Excellent Transparency Enhancement

  • The new UsageEstimator component significantly improves pricing transparency
  • Real-time cost calculation helps users understand actual costs
  • Usage-based pricing links in the comparison table provide clear context

2. Solid Architecture & Performance

  • Proper useMemo() usage for expensive calculations in UsageEstimator.tsx:45-51
  • Well-structured tiered pricing logic from shared @helicone-package/pricing
  • Good separation of concerns with separate pricing calculator logic

3. Code Quality

  • Strong TypeScript typing throughout
  • Consistent React patterns with proper hooks usage
  • Clean component decomposition

4. Design System Compliance

  • Proper use of semantic color tokens (bg-background, text-foreground, etc.)
  • Consistent spacing with flexbox + gap patterns
  • Appropriate icon usage from lucide-react

Issues & Improvements:

🟡 Minor Issues (should fix):

  1. Design System Violations (UsageEstimator.tsx:57-58, 64)

    // ❌ Using raw colors instead of semantic tokens
    <h2 className="text-2xl font-bold text-slate-900">
    <div className="border border-slate-200 rounded-lg bg-white">
    
    // ✅ Should use semantic tokens
    <h2 className="text-2xl font-bold text-foreground">
    <div className="border border-border rounded-lg bg-card">
  2. Typography System Not Used (UsageEstimator.tsx:57)

    // ❌ Manual heading styles
    <h2 className="text-2xl font-bold text-slate-900">
    
    // ✅ Use design system typography
    import { H2 } from "@/components/ui/typography"
    <H2>Pricing calculator</H2>
  3. Missing Input Validation (UsageEstimator.tsx:87)

    // ❌ No validation for negative/invalid values
    onChange={(e) => setTokensPerRequest(Number(e.target.value) || 0)}
    
    // ✅ Add proper validation
    onChange={(e) => {
      const value = Math.max(0, Number(e.target.value) || 0);
      setTokensPerRequest(value);
    }}
  4. Inconsistent Icon Library (PricingComparisonTable.tsx:4, UsageEstimator.tsx:4)

    • Mixing @heroicons/react and lucide-react
    • Should standardize on lucide-react per design system guidelines

🟢 Good Practices Observed:

  • Proper accessibility with semantic HTML elements
  • Responsive design patterns with breakpoints
  • Efficient re-renders with memoization
  • Clean data transformations in pricing tier mapping

🔵 Performance Notes:

  • Slider component could benefit from useCallback for change handlers
  • Storage calculation (4 bytes per token) is reasonable but could be made configurable

Suggestions Summary:

  1. Replace raw colors with semantic tokens in UsageEstimator component
  2. Use typography components (H2, P, etc.) instead of manual heading styles
  3. Add input validation for tokens per request field
  4. Standardize on lucide-react for all icons
  5. Consider making storage calculation configurable (4 bytes per token assumption)

No Critical Issues Found:

  • No security vulnerabilities detected
  • No breaking changes identified
  • Performance is well-optimized
  • No accessibility concerns

This PR successfully enhances pricing transparency and maintains good code quality. The improvements are minor and focused on design system consistency.


@colegottdank colegottdank merged commit 28bb238 into main Jan 20, 2026
10 of 11 checks passed
@colegottdank colegottdank deleted the pricing-page-storage branch January 20, 2026 22:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant